package jmine.tec.test.metric.performance;

import java.math.BigDecimal;

import jmine.tec.test.Builder;

/**
 * @author bruno.ortiz
 */
public class PerformanceBuilder implements Builder<Performance> {

    private String performanceUnit;

    private BigDecimal performanceMesure;

    private Boolean isRelevant;

    /**
     * @return PerformanceBuilder
     */
    public static PerformanceBuilder umaPerformance() {
        return new PerformanceBuilder();
    }

    /**
     * @param value performanceUnit
     * @return PerformanceBuilder
     */
    public PerformanceBuilder comUnidadeDePerformance(String value) {
        this.performanceUnit = value;
        return this;
    }

    /**
     * @param value performanceMesure
     * @return PerformanceBuilder
     */
    public PerformanceBuilder comUmaMedidaDePerformance(BigDecimal value) {
        this.performanceMesure = value;
        return this;
    }

    /**
     * @param value performanceIsRelevant
     * @return PerformanceBuilder
     */
    public PerformanceBuilder comAtributoIsRelevant(Boolean value) {
        this.isRelevant = value;
        return this;
    }

    /**
     * @return Performance
     */
    public Performance build() {
        return new Performance(this.performanceUnit, this.performanceMesure, this.isRelevant);
    }

}
